<?php

/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2019\6\14 0014
 * Time: 21:39
 */
namespace BigVideo\IMooc\UserStorage;

class User
{
    /**
     * @var int
     */
    private $id;

    /**
     * @var string
     */
    private $name;

    /**
     * @var string
     */
    private $phone;

    /**
     * @var \DateTime
     */
    private $craated;

    public function __construct()
    {
        $this->setCraated(new \DateTime());
    }

    /**
     * @return int
     */
    public function getId(): int
    {
        return $this->id;
    }

    /**
     * @param string $name
     */
    public function setName(string $name)
    {
        $this->name = $name;
    }

    /**
     * @return string
     */
    public function getName(): string
    {
        return $this->name;
    }

    /**
     * @param string $phone
     */
    public function setPhone(string $phone)
    {
        $this->phone = $phone;
    }

    /**
     * @return string
     */
    public function getPhone(): string
    {
        return $this->phone;
    }

    /**
     * @param \DateTime $craated
     */
    public function setCraated(\DateTime $craated)
    {
        $this->craated = $craated;
    }

    /**
     * @return \DateTime
     */
    public function getCraated(): \DateTime
    {
        return $this->craated;
    }

}















